package com.rightsidetech.system.mapper;

import com.rightsidetech.system.dtos.response.SysRoleDetailResp;
import com.rightsidetech.system.dtos.request.SysRoleReq;
import com.rightsidetech.system.dtos.response.SysRoleSelectResp;
import com.rightsidetech.system.dtos.response.SysRoleResp;
import com.rightsidetech.system.entity.SysRole;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SysRoleMapper {
    int deleteByPrimaryKey(Long id);

    int insert(SysRole record);

    int insertSelective(SysRole record);

    SysRole selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(SysRole record);

    int updateByPrimaryKey(SysRole record);

    List<SysRoleResp> selectList(SysRoleReq sysRoleReq) throws Exception;
    Long selectList_COUNT(SysRoleReq sysRoleReq) throws Exception;

    SysRole selectByName(@Param("name") String name) throws Exception;

    List<SysRoleSelectResp> selectChooseList() throws Exception;

    SysRoleDetailResp selectByRoleId(@Param("roleId") Long roleId) throws Exception;
}